<ul>
    <?php
    if (!isset($carts))
        $carts = Cart::getCartsofOwner();

    if (isset($carts)) {
        foreach ($carts as $cart) {
            $a = $cart->amount;
            $b = $cart->product->price;
            $c = $a*$b + $c;
            $_SESSION['price'] = $c;           
            printf('<li> <b>%s</b> <b>%s</b> | (Giá: %s*%sVNĐ) | (%s)</li>',
                    $cart->amount,                    
                    CHtml::link($cart->product->name,
                            array('product/view', 'id' => $cart->product->id)
                    ),
                    $cart->amount,
                    $cart->product->price,
                    CHtml::link('Xóa',
                            array('Cart/delete', 'id' => $cart->id)
                    )
            );
        }
        echo '<hr>';
        echo 'Thành tiền: '.$c.'VNĐ';
    }
    ?>
</ul>